#! /usr/bin/env python
# encoding=utf-8

from suds.client import Client

api = 'asdf'

url = 'http://api.bing.net/search.wsdl?AppID='+api
client = Client(url)

print client

request = client.factory.create('SearchRequest')
request.parameters.AppId = api

sourcetype = client.factory.create('SourceType')
arraysource = client.factory.create('ArrayOfSourceType')
arraysource.SourceType.append(sourcetype.Web)
request.parameters.Sources = arraysource

query = client.factory.create('Query')
query.SearchTerms = 'enchufa2'
request.parameters.Query = query
print query

result = client.service.Search(request)
print result

# versión facilona que sí funciona:
#from bingapi import bingapi
#bing = bingapi.Bing(api)
#result = bing.do_web_search('enchufa2')
#print result